import request from '@/utils/request'
/**
 * 渲染树形结构请求
 */
export function DeactivatedAPI() {
  return request({
    url: '/company/department'
  })
}
/**
 * 删除部门封装
 */
export function Deldetlet(id) {
  return request({
    method: 'DELETE',
    url: `/company/department/${id}`
  })
}
/**
 * 封装部门列表数据
 */
export function departMentsAPI(params) {
  return request({
    url: '/sys/user/simple',
    params

  })
}
/**
 * 提交表单，添加数据
 */
export function adddepartMensAPI(data) {
  return request({
    method: 'POST',
    url: '/company/department',
    data
  })
}
/**
 * 回显获取部门详情
 */
export function getDepartDetailApi(id) {
  return request({
    url: `/company/department/${id}`
  })
}
/**
 * 封装修改数据接口
 */
export function getXiuGaiAPI(from) {
  return request({
    method: 'PUT',
    url: `/company/department/${from.id}`,
    data: from
  })
}
